<?
include_once('config.php');
include_once('model/status_messages.php');

save_status($_POST['status_message'], Session::user()->id);
header("Location: wall.php");

function save_status($msg, $user_id){
	$status                 = new StatusMessages();
	$status->status_message = $msg;
	$status->user_id        = $user_id;
	$status->insert();
}
?>